// 应用配置常量
const ChatConfig = {
    MAX_MESSAGE_LENGTH: 1000,
    RECALL_TIME_LIMIT: 2 * 60 * 1000,
    TYPING_INDICATOR_TIMEOUT: 3000,
    RECONNECT_INTERVAL: 3000,
    MAX_RECONNECT_ATTEMPTS: 5,
    HEARTBEAT_INTERVAL: 30000,
    MESSAGE_PAGE_SIZE: 20
};

// 消息类型枚举
const MessageType = {
    TEXT: 'text',
    IMAGE: 'image',
    VOICE: 'voice',
    VIDEO: 'video',
    FILE: 'file'
};

// WebSocket消息类型
const WsMessageType = {
    NEW_MESSAGE: 'new_message',
    MESSAGE_RECALL: 'message_recall',
    MESSAGE_READ: 'message_read',
    TYPING: 'typing',
    USER_ONLINE: 'user_online',
    USER_OFFLINE: 'user_offline'
};